1. Field of the Invention
The present application relates to a program analysis method for monitoring and reporting data structure activity of a program. More particularly, the present application profiles basic blocks of a program by monitoring block arcs and provides reports on block and data structure activity of the program to tune the performance of the program when translated to executable program code.
2. Description of the Related Art
Computers typically use translators to transform programs written in high-level programming languages into a form that is machine executable. Translators are typically defined as language processors that accept source code as an input and produce as an output functionally equivalent programs, i.e., object code, that can then be linked by a link editor to form executable program code. One example of a commonly used translator is a compiler which translates high-level source code into machine language object code.
Compiler vendors are continuously trying to improve execution times of programs using various techniques. One such technique used by compiler vendors is to take profile data from the execution of an instrumented program and use the profile data to reorder the program's instructions to decrease the execution time of the executable program.
Current techniques used in obtaining profile data of a program imbed instrumentation into the executable program and then run the instrumented form of the program to obtain the profile data. However, current techniques that imbed instrumentation into the executable program have been known to affect the execution time of the instrumented form of the program. Some of the current techniques have been known to increase the execution time of the instrumented form of the program by as much as ten times the normal execution time. This occurs because the instrumented program dynamically allocates data stored by the program. Thus, a significant consideration in determining whether or not to profile an executable program is the time it would take an instrumented form of the program to obtain the necessary profile data.
Prior attempts to improve program performance altering data layout involved adjusting the storage patterns of non-dynamically allocated global variables. However, this technique does not appear to improve execution times of programs. Another attempt to solve this problem involved monitoring data activity by instrumenting the executing program and recording the data addresses that occur. However, programs so instrumented incur factors of 30 or more times the execution time of the program. In addition, the data produced by this approach is difficult to use productively. That is, the data obtained from this approach requires substantial additional processing before it can be correlated for engineering analysis.